-
Notifications
You must be signed in to change notification settings - Fork 17
Start of citro2d implementation #71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
woah, I totally missed this, but I was working on a similar thing. My implementation is very hacked together and not at all usable in a library form -- I'm just using it for a few side projects of my own. I'd love to be involved in this as a contributor if you're interested. |
|
Awesome work! I may contribute too. I have a low-priority task on my game roadmap: adding 3DS support to Bevy (my game is built on Bevy). This is doable because Bevy is extremely modular. All the modules my game needs—except the renderer, which uses std but will be replaced with a custom 3DS renderer—are already no_std. 3DS support in Bevy will grow progressively, and not all features may be implemented, as some don't make sense for the 3DS (e.g., heavy rendering techniques, advanced rendering pipelines, shader compilation from WGSL to 3DS-compliant shader language). Some fallback mechanisms may be added, allowing developers to provide a second, simpler shader that can be used when building for 3DS. What do you think about and do you have any considerations to share? |
|
Just imagine doing 3DS games with high level elements, without even seeing any of rendering and complicated stuff, hidden behind its ECS. Also, if you want for whatever reason compile your game to Web, Android, iOS, Linux, ..., you don't have to worry that much 😇 |
|
@heydocode :
I love that so much. I've barely touched Bevy, but I love its ECS so much and
I think it'd be amazing to have it ported to the 3DS.
my motivation for writing my citro2d wrapper, and the thing I'm looking for
the most, is a UI library that uses libcitro(3|2)d under-the-hood. I've messed
around with a few "graphics frameworks" that can render to a framebuffer
target (c.f. Slint, LVGL, and embedded-graphics), but their performance is
actually comically slow. I love the architectures of [clay](https://
www.nicbarker.com/clay) and egui for maybe making basing another "reinvented-
the-wheel" UI framework off of.
@fatfingers23 :
on the topic of contributing, -- putting aside «I'm just fumbling around and
am quite new to open source projects» -- I think it'd be best to start a new
repository for this (i.e. not within citro3d-rs) if you're interested in this
being a community-contributed project. my wrapper is very hacked together with
no regard for actually writing a usable library. taking a look at your initial
commits, I think you have a much-better-structured and safer implementation.
again, I'd *love* to be involved in this as a contributor.
El Saturday, April 26, 2025 3:29:15 PM Mountain Daylight Time, heydocode
escribió:
… heydocode left a comment (rust3ds/citro3d-rs#71)
Just imagine doing 3DS games with high level elements, without even seeing
any of rendering and complicated stuff, hidden behind its ECS. Also, if you
want for whatever reason compile your game to Web, Android, iOS, Linux,
..., you don't have to worry that much 😇
|
|
Hey, sorry. I've been away from my computer for the weekend. I was happy to see some discussions here! @heydocode bushrat may be who you'd like to talk to about 3DS and bevy. They led and did most of the @sheepy0125 But I am open to any suggestions from the rust3ds team! If we should clean this up and get it to work better with the current work on citro3d, or if they may be willing to create a citro2d repo, since it looks like the two will be somewhat similar, but different enough, a separate repo may be fine. |
|
I understand keeping it within the rust3ds org; I want to CC @FenrirWolf and @Meziu regarding that (& anyone else in the org!). I think basing a C2D crate that depends on C3D would be the 'sanest' architecture -- they're distinct but it's still helpful to hold onto the context citro3d::Instance provides for safety reasons.
P.S. it's so awesome to hear you're welcome to contributions! I know I probably seem super excited about this & that's just because I am -- I've wanted this for a long time.
|
|
Hey all, I guess I'm kinda the primary maintainer for I think we could definitely take on a new repo for this kind of work, although I'd want to make sure someone was willing to maintain it, as we already have kind of limited resources for that. This repo started its life in my github and was moved here eventually, so I could se a similar path would probably make sense. From a technical standpoint it's also possible it would make more sense to just keep them in the same repo (like this PR), so maybe that's worth looking at more closely before making any real decision. I'd encourage folks to continue working on this in @fatfingers23 's fork for now if you plan to work on this. Regarding Bevy integration: I had started working on it at one point (and did actually get something basic working) but more recently another team built (to my understanding) a whole game using https://github.com/Team-Yarg/bevy_3ds . I believe it depends on some changes still in review for this repo, which I have been slow to review 😞 If y'all want to continue this conversation it might be helpful to create a discussion post for threading purposes but since this is a draft PR I guess it's fine here too. It's awesome to see people still interested in further development of 3ds homebrew stuff, I hope to have more time to contribute and really get this repo into a more functional / maintained state soon! |
|
That sounds great to me. Thank you for taking the time to give us some insight, @ian-h-chamberlain! I agree and welcome any PRs for work done on citro2d to my fork. I have set the branch Thank you everyone! |
I've been working on a citro2d rust wrapper for citro2d. It's not finished, and it's still pretty early. But I have 2D Shapes rendering and figured this would be a good place to make a draft or share my work. My goal for it is to be able to make simple 2d games easily for the 3ds with rust and allow others to be able to do the same.
I plan to finish it out, but I'm sure we all know how that can go. So, I am making this draft PR so it is easy to find in relation to this project and get some feedback before continuing.
Concerns
TODO
The 2d_Shapes example minus the text on the bottom screen

A link to a video showing the breakout example